package com.zpark.controller;

import com.zpark.service.IUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * @author xiaoyu
 * @version 1.0 2022/9/22
 */
@Controller
@RequestMapping("/test")
public class TestController {
    @Autowired
    private IUserService userService;

    @RequestMapping("/demo01")
    public void test(){
        // 调用业务层代码
        userService.test(105);
    }

    @RequestMapping("/demo02")
    public void test01() {
        int num;
        num = 2 / 0;
    }
}
